package com.shrcl.engineerprocess.domain.impl;

import com.shrcl.engineerprocess.domain.EngineerTimerService;
import edu.fudan.mylang.pf.BaseService;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;

@Service("com.shrcl.engineerprocess.domain.impl.EngineerTimerServiceImpl")
public class EngineerTimerServiceImpl extends BaseService implements EngineerTimerService {
  @Scheduled(cron = "0 0 0 1 * ?")
  public void monthlyCostTimer() {
    final com.shrcl.engineerprocess.domain.EngineerStatus __created = com.shrcl.engineerprocess.domain.EngineerStatus.created;
    edu.fudan.mylang.pf.IGenericQuery<com.shrcl.engineerprocess.domain.Engineer> query=getObjectFactory().createGenericQuery(com.shrcl.engineerprocess.domain.Engineer.class,"select e from com.shrcl.engineerprocess.domain.impl.EngineerImpl as e where  e.Status = :__created ").setParameter("__created",__created);
    java.util.Collection<com.shrcl.engineerprocess.domain.Engineer> _list = query.list();
    final org.eclipse.xtext.xbase.lib.Procedures.Procedure1<com.shrcl.engineerprocess.domain.Engineer> _function = new org.eclipse.xtext.xbase.lib.Procedures.Procedure1<com.shrcl.engineerprocess.domain.Engineer>() {
    	public void apply(final com.shrcl.engineerprocess.domain.Engineer it) {
    		it.monthlyCostTimer();
    	}
    };
    org.eclipse.xtext.xbase.lib.IterableExtensions.<com.shrcl.engineerprocess.domain.Engineer>forEach(_list, _function);
    
    
  }
}
